// JavaScript Document

Bmob.initialize("89c847960e0592e0d5bce9dcec279d1f", "57011af2407303344821d8fee53dab25");
 //创建类和实例
//添加一条数据
function check(){
	var username,password;
 username=document.form1.t1.value;
 
 password=document.form1.t2.value;

//var password=parseFloat(document.form1.t3.value);
var user = new Bmob.User();
user.set("username", username);

user.set("password", password);
//user.set("email", "email@example.com");

// other fields can be set just like with Bmob.Object
user.set("phone", "415-392-0202");

user.signUp(null, {
  success: function(user) {
    // Hooray! Let them use the app now.
	//返回到上一成
	window.history.back(-1); 
  },
  error: function(user, error) {
    // Show the error message somewhere and let the user try again.
    alert("Error: " + error.code + " " + error.message);
  }
});
 }